<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>伪元素实现时间线</title>
    <style>
        body{
            background-color: burlywood;
        }
        div{
            width:500px;
            height:150px;
            border-left:5px solid white;
            position: relative;
        }
        div:before{
            content: '';
            width:25px;
            height:25px;
            border-radius: 50%;
            background-color: blueviolet;
            position: absolute;
            left:-15px;
            top:5px;
        }
        div:after{
            content: '';
            width:15px;
            height:15px;
            border-radius: 50%;
            background-color: rgba(255,255,255,0.5);
            position: absolute;
            left:-10px;
            top:10px;
        }
    </style>
</head>
<body>
<div></div>
<div></div>
<div></div>
</body>
</html>